#                                               -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.

AC_PREREQ(2.59)
AC_INIT(FULL-PACKAGE-NAME, VERSION, BUG-REPORT-ADDRESS)
AM_INIT_AUTOMAKE(greatoutdoors, 0.2)
AC_CONFIG_SRCDIR([config.h.in])
#AC_CONFIG_HEADER([config.h])
AM_CONFIG_HEADER([config.h])

# Checks for programs.
AC_PROG_CC
AC_PROG_LIBTOOL

# Checks for libraries.

# Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS([stdlib.h string.h unistd.h])

# Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST

# Checks for library functions.
AC_FUNC_MALLOC

AC_ARG_ENABLE([keck],
[  --enable-keck     Special case for building in the Keck lab],
[case "${enableval}" in
  yes) keck=true ;;
  no)  keck=false ;;
  *) AC_MSG_ERROR([bad value ${enableval} for --enable-debug]) ;;
esac],[keck=false])
AM_CONDITIONAL([KECK], [test x$keck = xtrue])

AC_CANONICAL_HOST
case "$host" in
  *-apple-darwin*) mac=true ;;
  *) mac=false ;;
esac
AM_CONDITIONAL([MAC], [test x$mac = xtrue])

AC_CONFIG_FILES([Makefile
                 src/Makefile
                 src/agent/Makefile
                 src/controller/Makefile
                 src/gamelogic/Makefile
                 src/gameview/Makefile
                 src/gui/Makefile
                 src/lua/Makefile
                 src/map/Makefile
                 src/utils/Makefile
                 img/Makefile
                 scripts/Makefile])
AC_OUTPUT
